package com.ly.dingtalk.service.role;

import java.util.List;

import com.dingtalk.api.request.OapiRoleAddRoleRequest;
import com.dingtalk.api.request.OapiRoleAddrolegroupRequest;
import com.dingtalk.api.request.OapiRoleAddrolesforempsRequest;
import com.dingtalk.api.request.OapiRoleListRequest;
import com.dingtalk.api.request.OapiRoleRemoverolesforempsRequest;
import com.dingtalk.api.request.OapiRoleScopeUpdateRequest;
import com.dingtalk.api.request.OapiRoleSimplelistRequest;
import com.dingtalk.api.request.OapiRoleUpdateRoleRequest;
import com.dingtalk.api.response.OapiRoleAddRoleResponse;
import com.dingtalk.api.response.OapiRoleAddrolegroupResponse;
import com.dingtalk.api.response.OapiRoleAddrolesforempsResponse;
import com.dingtalk.api.response.OapiRoleDeleteroleResponse;
import com.dingtalk.api.response.OapiRoleGetroleResponse;
import com.dingtalk.api.response.OapiRoleGetrolegroupResponse;
import com.dingtalk.api.response.OapiRoleListResponse;
import com.dingtalk.api.response.OapiRoleRemoverolesforempsResponse;
import com.dingtalk.api.response.OapiRoleScopeUpdateResponse;
import com.dingtalk.api.response.OapiRoleSimplelistResponse;
import com.dingtalk.api.response.OapiRoleUpdateRoleResponse;

import lombok.NonNull;

/**
 * 钉钉角色
 *
 * @author wangzhen
 */
public interface IDingRoleHandler {

    default List<OapiRoleListResponse.OpenRole> roles(@NonNull Long page, @NonNull Long size) {
        return null;
    }

    default List<OapiRoleSimplelistResponse.OpenEmpSimple> usersByRoleId(@NonNull Long roleId, @NonNull Long page,@NonNull Long size){
        return null;
    }
    
    /**
     * https://open.dingtalk.com/document/orgapp/add-a-role-group
     * @Description: 创建角色
     */
    OapiRoleAddrolegroupResponse addRoleGroup(OapiRoleAddrolegroupRequest req);
    /**
     * https://open.dingtalk.com/document/orgapp/add-role
     * @Description: 创建角色
     */
    OapiRoleAddRoleResponse addRole(OapiRoleAddRoleRequest req);
    /**
     * https://open.dingtalk.com/document/orgapp/update-role
     * @Description: 更新角色名称
     */
    OapiRoleUpdateRoleResponse updateRole(OapiRoleUpdateRoleRequest req);

    /**
     * https://open.dingtalk.com/document/orgapp/add-role-information-to-employees-in-batches
     * @Description: 批量增加员工角色
     */
    OapiRoleAddrolesforempsResponse addrolesforemps(OapiRoleAddrolesforempsRequest req);

    /**
     * https://open.dingtalk.com/document/orgapp/delete-role-information
     * @Description: TODO 删除角色
     */
    OapiRoleDeleteroleResponse deleterole(Long roleId);

    /**
     * https://open.dingtalk.com/document/orgapp/delete-the-color-information-of-employee-corners-in-batches
     * @Description: 批量删除员工角色
     */
    OapiRoleRemoverolesforempsResponse removerolesforemps(OapiRoleRemoverolesforempsRequest req);

    /**
     * https://open.dingtalk.com/document/orgapp/update-role-member-management-department-scope
     * @Description: 设定角色成员管理范围
     */
    OapiRoleScopeUpdateResponse update(OapiRoleScopeUpdateRequest req);

    /**
     * https://open.dingtalk.com/document/orgapp/obtains-the-role-group-information
     * @Description: 获取角色组列表 
     */
    OapiRoleGetrolegroupResponse getrolegroup(Long groupId);

    /**
     * https://open.dingtalk.com/document/orgapp/obtains-a-list-of-enterprise-roles
     * @Description: 获取角色列表
     */
    OapiRoleListResponse roleList(OapiRoleListRequest req);

    /**
     * https://open.dingtalk.com/document/orgapp/queries-role-details
     * @Description: 获取角色详情
     */
    OapiRoleGetroleResponse getrole(Long roleId);

    /**
     * 获取指定角色的员工列表
     * @Description: https://open.dingtalk.com/document/orgapp/obtain-the-list-of-employees-of-a-role
     */
    OapiRoleSimplelistResponse simplelist(OapiRoleSimplelistRequest req);
    
    
}
